//
// Created by 25429 on 2020/7/9.
//

#ifndef SIRIUS_TASK_LIMIT_UP_SELL_H
#define SIRIUS_TASK_LIMIT_UP_SELL_H


#include "strategy_engine.h"


class task_limit_up_sell : public strategy_task {
public:
    task_limit_up_sell(string name, trade_engine* trade) : strategy_task(
            std::move(name), trade) {
    }

    void init() override;

    void on_md_l2_mkt(const SiriusMDRspMarketField &mkt) override;

private:
    int m_block_money = 0;
    int m_max_block_money = 0;
    bool m_touch_limit_up = false;
    int m_fail_to_n_per = 99;
    int m_stop_price = 0;
};

#endif //SIRIUS_TASK_LIMIT_UP_SELL_H
